/*package com.hotvoice.android.task;

import android.content.ContentProvider;
import android.content.ContentResolver;
import android.content.ContentUris;
import android.content.ContentValues;
import android.content.Context;
import android.database.Cursor;
import android.database.SQLException;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;
import android.database.sqlite.SQLiteQueryBuilder;
import android.net.Uri;
import android.text.TextUtils;
import android.util.Log;
//import dalvik.annotation.Signature;
import java.util.HashMap;
import java.util.List;

import com.hotvoice.android.VoiceRecorder;
import com.hotvoice.android.VoiceRecorder.Recorder;

public class CallRecordHistory extends ContentProvider
{
  public static final Uri CONTENT_URI = Uri.parse("content://cn.airrunner.voicerecorder.callrecordhistory");
  private static final String DATABASE_NAME = "voice_record.db";
  private static final int DATABASE_VERSION = 2;
  private static final String NOTES_TABLE_NAME = "call_history";
  private static final String TAG = "CallRecordHistory";

  //@Signature({"Ljava/util/HashMap", "<", "Ljava/lang/String;", "Ljava/lang/String;", ">;"})
  private static HashMap sNotesProjectionMap = new HashMap();
  private DatabaseHelper mOpenHelper;

  static
  {
    sNotesProjectionMap.put("_id", "_id");
    sNotesProjectionMap.put("linenumber", "linenumber");
    sNotesProjectionMap.put("filepath", "filepath");
    sNotesProjectionMap.put("started_time", "started_time");
    sNotesProjectionMap.put("ended_time", "ended_time");
  }

  public int delete(Uri paramUri, String paramString, String[] paramArrayOfString)
  {
    SQLiteDatabase localSQLiteDatabase = this.mOpenHelper.getWritableDatabase();
    String str1 = (String)paramUri.getPathSegments().get(1);
    String str2 = "call_history";
    StringBuilder localStringBuilder = new StringBuilder("_id=").append(str1);
    boolean bool = TextUtils.isEmpty(paramString);
    if (!bool);
    for (String str3 = " AND (" + paramString + ')'; ; str3 = "")
    {
      String str4 = str3;
      int i = localSQLiteDatabase.delete(str2, localStringBuilder, paramArrayOfString);
      getContext().getContentResolver().notifyChange(paramUri, null);
      return i;
    }
  }

  public String getType(Uri paramUri)
  {
    return "vnd.android.cursor.dir/vnd.google.note";
  }

  public Uri insert(Uri paramUri, ContentValues paramContentValues)
  {
    String str1 = null;
    if (paramContentValues != null);
    for (ContentValues localContentValues = new ContentValues(paramContentValues); ; localContentValues = new ContentValues())
    {
      Long localLong = Long.valueOf(System.currentTimeMillis());
      long l = this.mOpenHelper.getWritableDatabase().insert("call_history", str1, localContentValues);
      Object localObject;
      if (localObject <= 0L)
        break;
      Uri localUri = ContentUris.withAppendedId(VoiceRecorder.Recorder.CONTENT_URI, localObject);
      getContext().getContentResolver().notifyChange(localUri, str1);
      return localUri;
    }
    String str2 = "Failed to insert row into " + paramUri;
    throw new SQLException(str2);
  }

  public boolean onCreate()
  {
    Context localContext = getContext();
    DatabaseHelper localDatabaseHelper = new DatabaseHelper();
    this.mOpenHelper = localDatabaseHelper;
    return true;
  }

  public Cursor query(Uri paramUri, String[] paramArrayOfString1, String paramString1, String[] paramArrayOfString2, String paramString2)
  {
    String str1 = null;
    SQLiteQueryBuilder localSQLiteQueryBuilder = new SQLiteQueryBuilder();
    localSQLiteQueryBuilder.setTables("call_history");
    HashMap localHashMap = sNotesProjectionMap;
    localSQLiteQueryBuilder.setProjectionMap(localHashMap);
    if (TextUtils.isEmpty(paramString2));
    for (String str2 = "_ID DESC"; ; str2 = paramString2)
    {
      SQLiteDatabase localSQLiteDatabase = this.mOpenHelper.getReadableDatabase();
      String[] arrayOfString1 = paramArrayOfString1;
      String str3 = paramString1;
      String[] arrayOfString2 = paramArrayOfString2;
      String str4 = str1;
      Cursor localCursor = localSQLiteQueryBuilder.query(localSQLiteDatabase, arrayOfString1, str3, arrayOfString2, str1, str4, str2);
      ContentResolver localContentResolver = getContext().getContentResolver();
      localCursor.setNotificationUri(localContentResolver, paramUri);
      return localCursor;
    }
  }

  public int update(Uri paramUri, ContentValues paramContentValues, String paramString, String[] paramArrayOfString)
  {
    return null;
  }

  class DatabaseHelper extends SQLiteOpenHelper
  {
    DatabaseHelper()
    {
      super("voice_record.db", null, 2);
    }

    public void onCreate(SQLiteDatabase paramSQLiteDatabase)
    {
      paramSQLiteDatabase.execSQL("CREATE TABLE call_history (_id INTEGER PRIMARY KEY,linenumber TEXT,filepath TEXT,started_time INTEGER,ended_time INTEGER);");
    }

    public void onUpgrade(SQLiteDatabase paramSQLiteDatabase, int paramInt1, int paramInt2)
    {
      String str = "Upgrading database from version " + paramInt1 + " to " + paramInt2 + ", which will destroy all old data";
      Log.w("CallRecordHistory", str);
      paramSQLiteDatabase.execSQL("DROP TABLE IF EXISTS call_history");
      onCreate(paramSQLiteDatabase);
    }
  }
}*/